<?php

namespace App\Http\Requests\Admin\RecommendPosition;

use App\Http\Requests\Request;

class StoreRequest extends Request
{
    /**
     * Determine if the user is authorized to make this request.
     *
     * @return bool
     */
    public function authorize()
    {
        return true;
    }

    /**
     * Get the validation rules that apply to the request.
     *
     * @return array
     */
    public function rules()
    {
        return [
            'name' => 'required',
            'identification' => 'required|unique:recommend_position',
        ];
    }

    public function messages()
    {
        return [
            'name.required'=>'请填写推荐位置名称',
            'identification.required'=>'请填写标识位',
            'identification.unique'=>'该标识位已存在，请重新填写',
          
        ];

    }
}
